package com.achang.achangmall.product.service;

import com.achang.achangmall.product.vo.Catelog2Vo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.achang.common.utils.PageUtils;
import com.achang.achangmall.product.entity.CategoryEntity;

import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author achang
 * @email 995931576@qq.com
 * @date 2021-09-20 22:51:19
 */
public interface CategoryService extends IService<CategoryEntity> {

    PageUtils queryPage(Map<String, Object> params);

    //查出所有分类以及子分类，以树形结构组装
    List<CategoryEntity> listTree();

    void removeCategory(Long[] catIds);

    //找到catelogId的完整路径:[父/子/孙]
    Long[] findCatelogPath(Long catelogId);

    List<CategoryEntity> getLevel1Categorys();

    Map<Long, List<Catelog2Vo>>  getCatelogJson();
}

